Skip to content

Conversation

@OwainWilliams
Copy link
Contributor

After an initial conversation on #20186 I've started working on adding Summary and Descriptions to the Management API Swagger docs.

This is an update to the Culture and DocumentVersion endpoints. Started with a couple of the smaller endpoints so that I can make updates if required and get an idea of what is being looked for.

OwainWilliams and others added 4 commits September 25, 2025 08:49
Making a small change to the Readme to signpost the Forum now that it's the place to go for help/questions
Update README.md with information about the forum
Copilot AI review requested due to automatic review settings October 18, 2025 19:45
@github-actions
Copy link

github-actions bot commented Oct 18, 2025

Hi there @OwainWilliams, thank you for this contribution! 👍

While we wait for one of the Core Collaborators team to have a look at your work, we wanted to let you know about that we have a checklist for some of the things we will consider during review:

  • It's clear what problem this is solving, there's a connected issue or a description of what the changes do and how to test them
  • The automated tests all pass (see "Checks" tab on this PR)
  • The level of security for this contribution is the same or improved
  • The level of performance for this contribution is the same or improved
  • Avoids creating breaking changes; note that behavioral changes might also be perceived as breaking
  • If this is a new feature, Umbraco HQ provided guidance on the implementation beforehand
  • 💡 The contribution looks original and the contributor is presumably allowed to share it

Don't worry if you got something wrong. We like to think of a pull request as the start of a conversation, we're happy to provide guidance on improving your contribution.

If you realize that you might want to make some changes then you can do that by adding new commits to the branch you created for this work and pushing new commits. They should then automatically show up as updates to this pull request.

Thanks, from your friendly Umbraco GitHub bot 🤖 🙂

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Adds EndpointSummary and EndpointDescription attributes to selected Management API endpoints to improve Swagger/OpenAPI documentation.

  • Adds summaries/descriptions to DocumentVersion endpoints (list, get-by-id, rollback, set prevent-cleanup).
  • Adds summaries/descriptions to Culture list endpoint.

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
src/Umbraco.Cms.Api.Management/Controllers/DocumentVersion/UpdatePreventCleanupDocumentVersionController.cs Adds summary/description explaining the prevent-cleanup flag operation.
src/Umbraco.Cms.Api.Management/Controllers/DocumentVersion/RollbackDocumentVersionController.cs Adds summary/description for rolling back a document to a specific version.
src/Umbraco.Cms.Api.Management/Controllers/DocumentVersion/ByKeyDocumentVersionController.cs Adds summary/description for fetching a specific document version by ID.
src/Umbraco.Cms.Api.Management/Controllers/DocumentVersion/AllDocumentVersionController.cs Adds summary/description for listing versions of a document (paged).
src/Umbraco.Cms.Api.Management/Controllers/Culture/AllCultureController.cs Adds summary/description for listing available cultures (paged).

Copy link
Contributor

@AndyButland AndyButland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks very much for kicking this off @OwainWilliams. I had a look over and made a few suggestions. Please see what you think - in some cases you may not agree and if so, please do say so or suggest further improvement. We can tweak further perhaps to set the pattens moving forward.

In the suggestions I've tried to standardise a little so we consistently use certain terms and punctuation, have simplified in some cases so we don't create an undue burden on ourselves going forward in describing every field or parameter, and avoided repeating something that's already in the Swagger UI. Finally, in a couple of cases I focussed more on the end result of the operation (so not just saying a flag is set for content clean up, but what this means in terms of the system behaviour).

OwainWilliams and others added 10 commits October 20, 2025 08:48
…DocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…DocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…eyDocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…eyDocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…lbackDocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…lbackDocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…atePreventCleanupDocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
…atePreventCleanupDocumentVersionController.cs

Co-authored-by: Andy Butland <[email protected]>
@OwainWilliams
Copy link
Contributor Author

Thanks @AndyButland - really appreciate the feedback. Sorry you had to do so much tidy up on it :) Hopefully it will give me and others a good guide though on what sort of language and info should be added to the summary and descriptions

@AndyButland
Copy link
Contributor

You're welcome - looks good to me now and I think is a reasonable reference also for moving forward. @kjac - do you have any thoughts at this stage please, before @OwainWilliams or anyone else looks to create further endpoint descriptions?

@kjac
Copy link
Contributor

kjac commented Oct 20, 2025

I have thoughts.

I think it's awesome 🤩

@AndyButland
Copy link
Contributor

Good to hear! So @OwainWilliams - please let us know what your plans are for these now. Although little and often is fine, it might make sense to do another round with a few more, and then we look to merge in and take others in future PRs. I think you should also retarget this PR to v17/dev, which will mean these would come at earliest in 17.1. Targeting main they'll be for 16.4, but I don't think they will make 17.0, so that's seems a little odd. And 17.1 gives a bit more time to be able to have a reasonable collection of endpoints documented. What do you think?

@OwainWilliams
Copy link
Contributor Author

I'll see if I can get another couple of smaller sections done over the coming days. Don't want to lose momentum on this. Maybe target a few that are further up the list on the swagger page. Then I'd aim to keep that going, tick off more over the coming weeks. How does that sound?

@OwainWilliams OwainWilliams changed the base branch from main to v17/dev October 20, 2025 16:13
OwainWilliams and others added 21 commits October 30, 2025 07:33
…terDataTypeFilterController.cs

Co-authored-by: Andy Butland <[email protected]>
…eyDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…renDataTypeTreeController.cs

Co-authored-by: Andy Butland <[email protected]>
…eyDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…eteDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…ateDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…eteDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…renDataTypeTreeController.cs

Co-authored-by: Andy Butland <[email protected]>
…ateDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…ateDataTypeFolderController.cs

Co-authored-by: Andy Butland <[email protected]>
…ies' of https://github.com/OwainWilliams/Umbraco-CMS into v17/task/updating-managment-api-descritpions-and-summaries
…torsDataTypeTreeController.cs

Co-authored-by: Andy Butland <[email protected]>
…hDataTypeItemController.cs

Co-authored-by: Andy Butland <[email protected]>
…/ReferencedByDataTypeController.cs

Co-authored-by: Andy Butland <[email protected]>
…torsDataTypeTreeController.cs

Co-authored-by: Andy Butland <[email protected]>
…/ReferencedByDataTypeController.cs

Co-authored-by: Andy Butland <[email protected]>
@AndyButland
Copy link
Contributor

@OwainWilliams - please see what you think: #20690. I gave this a try:

After that, I think we'll have some pretty good patterns in place. Wondering if you think it's worth throwing Copilot at it to see what it can do? Could just be it follows the examples we've not got in place, and it'll be a quicker job to review and update that write from scratch.

And it seemed to work as I'd hoped after a bit of back and forth as you'll see. Now we had some good examples, we could lean on this to at least to a pretty good first draft of the descriptions. Up to you, but perhaps it'll be a fair bit quicker for you to review and suggest updates to this - either via the GitHub UI, or take a branch from this PR branch and make a PR from your fork back to it - than to write them all from scratch.

@OwainWilliams
Copy link
Contributor Author

@AndyButland Looks like you had a long conversation with copilot 😄

Im a bit confused though on the next steps - did you want me to run copilot over this PR or leave this one as it is and continue working on #20690 or something else?

Happy to do what ever is needed, just wasn't 100% sure on what was being suggested.

@AndyButland
Copy link
Contributor

Of course it's all up to you, but I was thinking we could:

  • Approve this one and leave as is, though expect to merge it in shortly.
  • Rather than start a long journey of documenting all the other API endpoints manually, use Add endpoint descriptions to all Management API controllers #20690 as a starting point for completing the job. Either you could review that PR - leaving suggestions where you think you can improve what the AI came up with, and I can apply them. Or you could use this PR's branch copilot/add-endpoint-descriptions-api as a base, create a branch in your fork and submit your changes as a PR to merge back into copilot/add-endpoint-descriptions-api. And then we merge that in, and finally Add endpoint descriptions to all Management API controllers #20690 into main.

@OwainWilliams
Copy link
Contributor Author

Ah, great, thanks @AndyButland - That all makes sense. I'm happy to take a look at your PR, make adjustments to it and go from there. I don't see any point forking from your work already - seems like an unrequired extra step.

Lets close this one off and I'll take a look at your other PR and make any suggestions

@AndyButland
Copy link
Contributor

No need to close this one - I would say for the endpoints it covers, it takes precedence over the other, as it established the patterns and I'd rather we have the human ones as preference! But suggest we keep it open until the other one is reviewed, and then we can have all merged in at once.

@OwainWilliams
Copy link
Contributor Author

Sorry - when I said Close, I meant, not do any more to this one and I'll pick up the other PR :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants